package 数据结构.数组;

import org.junit.Test;

/**
 * @author Veng Su 1344114844@qq.com
 * @date 2018/7/15 10:23
 */
public class Main {
    /**
     * 数组简单使用和遍历
     */
    @Test
    public void test(){
        int[] arr=new int[100];
        for (int i= 0; i <10; i++) {
            arr[i]=i;
        }
        System.out.println(arr[99]);
        int[] scores=new int[]{100,96,66};
        for (int score : scores) {
            System.out.println(score);
        }
        scores[0]=98;

    }
    @Test
    public void TestArray(){
        Array<String> array=new Array<>(2);
        array.addLast("jjjj");
        array.addLast("kkk");
        array.addLast("lll");
        array.addLast("ddd");
        array.addLast("ds");
        System.out.println(array.removeOneElement("jjjj"));
        System.out.println(array.get(0));
        System.out.println(array.contains("kkk"));
        System.out.println(array.toString());
    }
}
